package com.qk.management.mapper;

import com.qk.entity.Role;
import org.apache.ibatis.annotations.*;

import java.util.List;

@Mapper
public interface RoleMapper {

    @Insert("insert into role(name,label,remark,create_time,update_time) values(#{name},#{label},#{remark},#{createTime},#{updateTime})")
    void insert(Role role);

    @Delete("delete from role where id=#{roleid}")
    void deleteById(Integer roleid);

    void updateRole(Role role);


    List<Role> listRole();


    List<Role> list(@Param("name") String name, @Param("label") String label);

    @Select("select * from role where id=#{roleid}")
    Role selectById(Integer roleid);
}
